package cn.wolfcode.crm.util;

import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;

public class MyJsonMapUtil {

    private static ObjectMapper mapper = new ObjectMapper();

    public static String toJsonString(Object obj){

        try {
            return mapper.writeValueAsString( obj );
        } catch (JsonProcessingException e) {
            throw new RuntimeException( e );
        }
    }
}
